<template>
    <div>
        <h1>News</h1>
        <button @click="clickHandler">点击</button>
        <el-button>默认按钮</el-button>
        <el-button @click="clickHandler" type="primary">主要按钮</el-button>
        <el-button type="success">成功按钮</el-button>
        <el-button type="info">信息按钮</el-button>
        <el-button type="warning">警告按钮</el-button>
        <el-button type="danger">危险按钮</el-button>

    </div>
</template>

<script>
    export default {
        name: "News",
        methods: {
            async clickHandler() {
                // 组件实例对象里面可以直接调用插值上面的方法
                this.$dialog('我是news页面调用的！');
                let url = '/api/news/flist?pageSize=1&cate_id=%E7%A7%91%E6%8A%80%E5%85%B4%E5%9B%BD';
                let info = await this.$httpd.get(url);
                console.log(info);

            }
        }
    }
</script>

<style scoped>

</style>
